package com.company.cloud.mall.modules.bus.consumer;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.stereotype.Service;

import com.company.cloud.common.mq.redis.client.consumer.ISaasMqConsumer;
import com.company.cloud.common.mq.redis.client.consumer.MQConsumeMessage;
import com.company.cloud.common.mq.redis.client.consumer.MQSaasResult;
import com.company.cloud.common.mq.redis.client.consumer.annotation.MQRedisConsumer;
import com.company.common.server.config.mq.constant.MQTopicKeys;

import lombok.extern.log4j.Log4j2;


/**
 * 商品变化
 * */
@Log4j2
@MQRedisConsumer(topic = MQTopicKeys.MQ_PRD_Change_Topic,group="mall_prd",consumer = "mallPrdComsumer")
@Service
public class ProductRedisComsumer implements ISaasMqConsumer {
	
	
	@Override
	public MQSaasResult consume(MQConsumeMessage data) throws Exception {
		return null;
	}

//	
//	@Autowired
//	private ShopMQService shopMQService;
//	
//	@Override
//	public MqResult consume(String data) throws Exception {
//		logger.info(StrUtil.format("+++++ProductDelMQComsumer[商品删除]:{0}", data));
//		DataMapEntity entity= JSON.parseObject(data, DataMapEntity.class);
//		String type= MapUtil.getStr(entity, "type");
//		String id= MapUtil.getStr(entity, "id");
//		shopMQService.delObj(type, id);
//		return MqResult.SUCCESS;
//	}
	
	
	
	

}
